package com.lx.patterns.mediator;

/**
 * @ClassName Tenant
 * @Description: 房屋租赁人
 * @Author: 落雪
 * @CreateDate: 2025/2/15 10:39
 * @UpdateUser: 落雪
 * @UpdateDate: 2025/2/15 10:39
 * @UpdateRemark:
 * @Version: 1.0
 */
public class Tenant extends Person{
    public Tenant(String name, Mediator mediator) {
        super(name, mediator);
    }

    public void contact(String message) {
        mediator.contact(message, this);
    }

    public void getMessage(String message) {
        System.out.println("租房人 " + name + " 收到信息，信息是：" + message);
    }
}
